package com.fashopcliente.vo;
import org.springframework.roo.addon.javabean.RooJavaBean;
import org.springframework.roo.addon.jpa.activerecord.RooJpaActiveRecord;
import org.springframework.roo.addon.tostring.RooToString;
import javax.validation.constraints.NotNull;
import javax.persistence.ManyToOne;
import java.util.HashSet;
import java.util.Set;
import javax.persistence.CascadeType;
import javax.persistence.OneToMany;

@RooJavaBean
@RooToString
@RooJpaActiveRecord
public class Beacon {

    /**
     */
    @NotNull
    private Long idbeacon;

    /**
     */
    @NotNull
    private String uuid;

    /**
     */
    @NotNull
    private int major;

    /**
     */
    @NotNull
    private int minor;

    /**
     */
    @NotNull
    private String proximidad;

    /**
     */
    @NotNull
    private String alias;

    /**
     */
    @NotNull
    private Long contador;

    /**
     */
    @NotNull
    private String generico1;

    /**
     */
    @ManyToOne
    private Lugar lugar_idlugar;

    /**
     */
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "beacon_idbeacon")
    private Set<Mensaje> idmensaje = new HashSet<Mensaje>();
}
